perm filename DLIB.HDR[ETH,ROB] blob
sn#494239 filedate 1980-01-15 generic text, type T, neo UTF8
// Copyright Xerox Corporation 1979
// BCPL library header 01-May-1974
GLOBAL $(GLOB
// convention for describing file manipulation
// is:-
// D = ddname, a bcpl string holding a file title
// S = strpointer, a +ve value used by the library
// E = error, a negative result
// COS = current output stream
// CIS = current input stream
// [ ] = type of arguments and result
// ( ) = environment used by call
// *** = not implemented
//
// ddname = devN:flname.ext[uic]/LN:ln/DD:opt
// ln = data set logical name
// opt = .OPEN options: B = binary
// E = open for extension
// F = fast stream
// R = do not delete on op
// S = echo-suppress
//
// routines marked by ** are intended for use by the
// system, and should not normally be touched !!!
START : 1 // rt entry point
STOP : 2 // rt exit
ODT : 3 // rt entered externally by use of .OD command
RESTART : 4 // rt entered externally by use of .RE command
STACKBASE : 5 // v ** addr of base stack
GLOBALSIZE : 6 // v ** number of globals in global vector
STORESIZE : 7 // v ** addr of highest store location in program
IOERRCOUNT : 8 // v count of i/o errors
FINDINPUT :10 // fn creates input stream [D->S,E]
FINDOUTPUT :11 // fn creates output stream [D->S,E]
FINDFASTINPUT :12 // fn creates 'fast'input stream by implicit /DD:F
FINDFASTOUTPUT :13 // fn creates 'fast' output stream by implicit /DD:F
SELECTINPUT :14 // fn selects input stream as current
SELECTOUTPUT :15 // fn selects output stream as current
SYSIN :16 // v default input stream (KB:/LN:CMI)
SYSOUT :17 // v default output stream (KB:/LN:CMO)
ENDREAD :18 // fn terminate current input; unset selection [(CIS)]
ENDWRITE :19 // fn terminate current output stream [(COS)]
REWIND :20 // fn rewinds current input if possible [(CIS)->S,0,E]
ENDTOINPUT :21 // fn closes current output, and reopens for input [(COS)->S,0,E]
RDCH :22 // fn read a character from current input [(CIS) ?->CH,ENDSTREAMCH]
WRCH :23 // fn write a char to current output [(COS) CH->?,EOM]
INPUT :24 // fn returns currently selected input pointer (or 0)
OUTPUT :25 // fn returns currently selected output pointer (or 0)
UNRDCH :26 // rt causes RDCH to return same char as last time [(CIS)]
STARTIO :38 // rt ** (library initialization routine called by system)
ENDIO :39 // rt ** (library tidy-up called at end of day)
STATUSFILE :40 // fn return status of 'file [D->V,E]'
DELETEFILE :41 // fn delete 'file'; no errors [D->?]
RENAMEFILE :42 // fn rename file1 as file2 [D1,D2->0,E]
UNPACKTITLE :43 // fn unpack dos title to standard vector [D->D,E]
OVERLAY :44 // fn load overlay file, resetting used globals [d->0,e]
DATE :45 // fn returns date as given bcpl string (v=vec 5) [v->s]
TOD :46 // fn returns time of day, ditto. (v=vec 5) [v->s]
CHANGEPHASE :47 // fn causes named program to be loaded and entered
TIME :50 // fn returns number of clock ticks since start [***]
LEVEL :51 // fn returns P-pointer for use by longjump
LONGJUMP :52 // rt causes non-local jump
APTOVEC :53 // rt good old aptovec
RBYTE :54 // fn takes m/c type address
WBYTE :55 // rt ditto
PACKSTRING :56 // fn pack vec char into string
UNPACKSTRING :57 // fn unpack string into vector
GETBYTE :58 // fn get a byte from a vector
PUTBYTE :59 // rt put a byte in a vector
NEWLINE :70 // rt prints a newline on current output
WRITEN :71 // rt writes a decimal number
WRITED :72 // rt
WRITEHEX :73 // rt writes a hex number [***]
WRITEOCT :74 // rt writes in octal
WRITES :75 // rt write a string
WRITEF :76 // rt general purpose format driven op rtn
READN :77 // fn read a decimal number
TERMINATOR :78 // v terminating char from readn
FINDTITLES :79 // fn csi style operation, titles + ext into strings
NEWPAGE :87 // rt ***
WRITEARG :88 // rt ***
MAPSTORE :90 // rt prints out routine names and entry counts
MAPON :91 // rt turns mapstore counting on (default=on)
MAPOFF :92 // rt turns mapstore counting off
MAPGLOBALS :93 // rt prints global vector contents
POSTMORTEM :94 // rt unwinds the bcpl stack and prints it
$)GLOB
MANIFEST $(MAN // SYSTEM MANIFEST CONSTANTS
ENDSTREAMCH = -1
BYTESPERWORD = 2
MAXINT =32767
$)MAN